約 2,592,085 件
https://w.atwiki.jp/chihiro1710/pages/13.html
インストール $su $password #yum install emacs emacs-common テキストのコピー 1 ctrl + @ でマーク(スタート位置) 2 M + W (エンド位置)でコピー 3 Ctrl + y で貼り付け
https://w.atwiki.jp/nkym_memo/pages/31.html
;; .emacs ;; ;; Last Updated 2010/12/14 Tue 02 31 29 ;; (if window-system (progn ;; 文字の色を設定 (add-to-list 'default-frame-alist '(foreground-color . "white")) ;; 背景色を設定 (add-to-list 'default-frame-alist '(background-color . "gray7")) ;; カーソルの色を設定 (add-to-list 'default-frame-alist '(cursor-color . "SlateBlue2")) ;; ;; マウスポインタの色を設定 ;; (add-to-list 'default-frame-alist '(mouse-color . "SlateBlue2")) ;; ;; モードラインの文字の色を設定 ;; (set-face-foreground 'modeline "white") ;; ;; モードラインの背景色を設定 ;; (set-face-background 'modeline "MediumPurple2") ;; ;; 選択中のリージョンの色を設定 (set-face-background 'region "Dark Slate Grey") ;; ;; モードライン(アクティブでないバッファ)の文字色を設定 ;; (set-face-foreground 'mode-line-inactive "gray30") ;; ;; モードライン(アクティブでないバッファ)の背景色を設定 ;; (set-face-background 'mode-line-inactive "gray85") )) ;;auto-install.elのインストール手順 ;; $mkdir -p ~/.emacs.d/auto-install ;; cd ~/.emacs.d/auto-install ;; wget http //www.emacswiki.org/emacs/download/auto-install.el ;; emacs --batch -Q -f batch-byte-compile auto-install.el ;;;Emacs Lispインストーラを利用 (add-to-list 'load-path "~/.emacs.d/auto-install") ;;(install-elisp-from-emacswiki "auto-install.el") ;(require 'auto-install) ;;起動時にEmacswikiのページを補完候補に加える ;(auto-install-update-emacswiki-package-name t) ;;install-elisp.el互換モード ;(auto-install-compatibility-setup) ;;ediff関連のバッファを一つのフレームにまとめる (setq ediff-window-setup-function 'ediff-setup-windows-plain) ;;; 基本設定 ;; スタートアップを非表示 (setq inhibit-startup-screen -1) ;; ビープ音を消す (setq ring-bell-function 'ignore) ;; 現在行に色をつける (global-hl-line-mode 1) ;; その行の色 (set-face-background 'hl-line "black") ;; 履歴を次回Emacs起動時にも保存する (savehist-mode 1) ;; 対応する括弧を光らせる (show-paren-mode 1) ;; カーソルの位置が何文字目かを表示する (column-number-mode t) ;; バックアップファイルを作らない (setq backup-inhibited t) ;; Xでのクリップボードを共有 (setq x-select-enable-clipboard t) ;; yes-or-noをy-or-nに省略 (defalias 'yes-or-no-p 'y-or-n-p) ;; 行の先頭でC-kを一回押すだけで行全体を消去する (setq kill-whole-line t) ;; ツールバーを非表示 (tool-bar-mode -1) ;; メニューバーを非表示 (menu-bar-mode -1) ;; 圧縮されたファイルも編集できるようにする (auto-compression-mode t) ;; スクロールを一行ずつにする (setq scroll-step 1) ;;; 現在の関数名をモードラインに表示 (which-function-mode 1) ;;; emacsclient ;; ファイルを現在のemacsで開く (server-start) ;; キーバインドの変更 ;; 指定の行に移る (global-set-key "\M-g" 'goto-line) ;; undo (global-set-key "\C-z" 'undo) ;; ウィンドウの移動をM-tに (global-set-key "\M-t" 'other-window) ;; C-hをBackSpaceに (global-set-key "\C-h" 'delete-backward-char) ;; M-x compile を C-. に (global-set-key [?\C-\.] 'compile) ;;; 初期フレームの設定 (setq initial-frame-alist (append '( (width . 47) ; フレーム幅(文字数) (height . 63)) ; フレーム高(文字数) initial-frame-alist)) ;;; 新規フレームのデフォルト設定 (setq default-frame-alist (append '((width . 47); フレーム幅(文字数) (height . 63)); フレーム高(文字数) default-frame-alist)) ;;; ファイル更新日を自動的に書き換える。 ;; ファイルの頭に "last updated "をつけくわえればよい (require 'time-stamp) ;; 日本語で日付を入れたくないのでlocaleをCにする (defun time-stamp-with-locale-c () (let ((system-time-locale "C")) (time-stamp) nil)) (if (not (memq 'time-stamp-with-locale-c write-file-hooks)) (add-hook 'write-file-hooks 'time-stamp-with-locale-c)) (setq time-stamp-active t) (setq time-stamp-start "Last Updated ") (setq time-stamp-format "%04y/%02m/%02d %3a %02H %02M %02S") (setq time-stamp-end " ") ;;;Last Updated の後に空白2つ以上いれると置換 ;;; タイトルバーにファイル名を表示する (setq frame-title-format (format "emacs@%s %%f" (system-name))) ;;; ファイルの自動挿入 (auto-insert-mode) ;; 自動挿入するファイルのあるディレクトリ ;; 最後の/は必須 (setq auto-insert-directory "~/.emacs.d/insert/") ;; 自動挿入するファイル (define-auto-insert "\\.c" "c-template.c") ;;; viewer.el view-modeの設定 ;; M-x install-elisp-from-emacswiki viewer.el ;; ;; C-x C-rでview-modeでファイルを開く (setq view-read-only t) ;; 書き込み不能な場合はview-modeを抜けないように (require 'viewer) (viewer-stay-in-setup) ;; .log .out .datファイルをview-modeで開く (setq view-mode-by-default-regexp "\\.log") (setq view-mode-by-default-regexp "\\.out") (setq view-mode-by-default-regexp "\\.dat") ;;; view-mode時にモードラインに色をつける ;; 色名を指定 (setq viewer-modeline-color-unwritable "tomato") (setq viewer-modeline-color-view "orange") (viewer-change-modeline-color-setup) ;; view-mode時のキーバインド (define-key view-mode-map "h" 'backward-char) (define-key view-mode-map "j" 'next-line) (define-key view-mode-map "k" 'previous-line) (define-key view-mode-map "l" 'forward-char) (define-key view-mode-map "J" 'View-scroll-line-forward) (define-key view-mode-map "K" 'View-scroll-line-backward) (define-key view-mode-map "b" 'scroll-down) (define-key view-mode-map " " 'scroll-up) ;; bm.el (define-key view-mode-map "m" 'bm-toggle) (define-key view-mode-map "[" 'bm-previous) (define-key view-mode-map "]" 'bm-next) ;; view-modeを有効・無効にする ;; 0.04秒以内に jk を同時押しでview-modeに移行 (require 'key-chord) (setq key-chord-two-keys-delay 0.04) (key-chord-mode 1) (key-chord-define-global "jk" 'view-mode) ;;; redo+.el (require 'redo+) ;; M-zに設定 (global-set-key "\M-z" 'redo) (setq undo-no-redo t); 過去のundoがredoされないようにする ;; 大量のundoに耐えられるようにする (setq undo-limit 600000) (setq undo-strong-limit 900000) ;;;fullscreen.el (require 'fullscreen) ;;; recentf-ext.el ;; install-elisp-from-emacswiki recentf-ext.el ;; 保存しておく数 (setq recentf-max-saved-items 3000) ;; 最近使ったファイルに加えないファイルを正規表現で指定する (setq recentf-exclude '("/TAGS$" "/var/tmp/")) (require 'recentf-ext) ;; f8をショートカットキーに (global-set-key [f8] 'recentf-open-files) ;;; auto-complete.el ;; install-elisp-from-emacswiki auto-complete.el ;(require 'auto-complete) ;(global-auto-complete-mode 1) ;;;col-highlight.el ;; auto-install-batch col-highlight.el ;(require 'col-highlight) ;(column-highlight-mode 1) ;;何もしないでいるとハイライトを始めるようにする場合 ;(toggle-highlight-column-when-idle 1) ;(col-highlight-set-interval 3) ;;; hippie-expand ;;; 略語展開の順を設定 (setq hippie-expand-try-functions-list '(try-expand-dabbrev try-expand-dabbrev-all-buffers try-expand-dabbrev-from-kill try-complete-file-name-partially try-complete-file-name try-expand-all-abbrevs try-expand-list try-expand-line try-complete-lisp-symbol-partially try-complete-lisp-symbol)) ;; キーバインドの変更 C-; (global-set-key [?\C-;] 'hippie-expand) ;;; ipa.el (require 'ipa) ;;; 背景色 (set-face-background 'highlight "lavender") ;;; sequential-command.el ;;; M-x auto-install-batch sequential-command (require 'sequential-command-config) (sequential-command-setup-keys) ;;; smartchr.el ;; M-x install-elisp ;; https //github.com/imakado/emacs-smartchr/raw/master/smartchr.el (require 'smartchr) ;; once "", twice " (global-set-key (kbd "\"") (smartchr '("\"`!!'\"" "\""))) ;; once '', twice ' (global-set-key (kbd "\'") (smartchr '("\'`!!'\'" "\'"))) ;;; auto-save-buffers.el ;; M-x install-elisp ;; http //homepage3.nifty.com/oatu/emacs/archives/auto-save-buffers.el (require 'auto-save-buffers) ;; アイドル2秒で保存 (run-with-idle-timer 0.2 t 'auto-save-buffers) (run-with-idle-timer 0.2 t 'auto-save-buffers "" ".ipa$") ;;; open-junk-file.el ;; M-x install-elisp-from-emacswiki open-junk-file.el ;; Usage M-x open-junk-file (require 'open-junk-file) (setq open-junk-file-format "~/junk/%Y-%m-%d-%H%M%S.") ;;; bm.el ;; M-x install-elisp ;; http //cvs.savannah.gnu.org/viewvc/*checkout*/bm/bm/bm.el (setq-default bm-buffer-persistence nil) (setq bm-restore-repository-on-load t) (require 'bm) (add-hook 'find-file-hooks 'bm-buffer-restore) (add-hook 'kill-buffer-hook 'bm-buffer-save) (add-hook 'after-save-hook 'bm-buffer-save) (add-hook 'after-revert-hook 'bm-buffer-restore) (add-hook 'vc-before-checkin-hook 'bm-buffer-save) (global-set-key (kbd "M-\\") 'bm-toggle) (global-set-key (kbd "M-[") 'bm-previous) (global-set-key (kbd "M-]") 'bm-next) ;;; Latex ;; 日本語コードをeuc-japanに (set-language-environment "Japanese") (set-default-coding-systems 'euc-japan) (set-terminal-coding-system 'euc-japan) ;;; Yatex (setq YaTeX-inhibit-prefix-letter nil)
https://w.atwiki.jp/musukure/pages/21.html
~/.bashrc export EDITOR=emacs .emacsの設定(meadow, emacs共通部分) リージョンをハイライト (transient-mark-mode t) 対応する括弧をハイライト (show-paren-mode t) サブバージョンを使う (require psvn) ビープ音を消す (setq visible-bell nil) cモード (add-hook c-mode-common-hook (lambda() (c-set-style "linux"))) タグ (setq tags-table-list ("..." "..." "...")) タグのうちかた(Meadowの場合、c /Meadow/bin/以下にあるetags.exeを使ってタグをうつ) $etags `find SRC -name "*.cpp"` -o HOGE/TAGS $etags -a `find INC -name "*.h"` -o HOGE/TAGS ヘッダファイルでもc++モード起動 (setq auto-mode-alist (append (("\\.h$" . c++mode)) auto-mode-alist)) バックアップファイルを作らない (setq backup-inhibited t) スタートアップを表示しない (setq inhibit-startup-message t) 行数表示 (line-number-mode t) C# (add-hook csharp-mode-hook (lambda () (setq c-basic-offset 4 tab-width 4 indent-tabs-mode nil))) (autoload csharp-mode "csharp-mode" "C# editing mode." t) (nconc auto-mode-alist (("\\.cs$" . csharp-mode))) meadow(Windows) emacs(Linux)
https://w.atwiki.jp/matsp/pages/18.html
Emacsの設定方法のうんたらかんたら Emacsの基本的なキーバインドはこちら こちらにキーバインドをまとめたチートシート(早見表)があるので、 Emacsを使いこなしたい人は見ておくといいかも(PDFファイルもあるので、DLして印刷もできます)。 ホームディレクトリの「.emacs」に以下の内容を記述すれば色々便利になります。 枠内の内容をそのままコピペして試してみてくださいねー 外部のEmacs Lispを使った拡張は別ページで解説 ;; ファイルの先頭が#!で始まるファイルは実行権をつけて保存(PerlとかRubyとか) (add-hook after-save-hook executable-make-buffer-file-executable-if-script-p) ;; 色をつける (auto-image-file-mode t) ;; Emacsのカラー設定(一例) (set-cursor-color "light blue") (set-background-color "gray30") (set-foreground-color "white") (set-face-background modeline "gainsboro") (set-face-background region "light blue") (set-face-foreground region "gray80") M-x list-colors-display で使うことができる色を見ることができます。 ;;終了時にオートセーブファイル(ファイル名の最後に~がついたファイル)を消す (setq delete-auto-save-files t) ;;ビープ音を鳴らさない (setq visible-bell t) ;;ビープ音の代わりの画面の反転さえもさせない (setq ring-bell-function (lambda ())) ;; tab を半角スペースに展開する (setq-default indent-tabs-mode nil) ;; モードラインにカラム数を表示 (column-number-mode 1) ;; emacsの起動画面を消す (setq inhibit-startup-message t) ;;ツールバー消去 (tool-bar-mode nil) ;; メニュー消去 (menu-bar-mode nil) ;; 1行全て(改行含めて)消す (setq kill-whole-line t) ;;スクロールバーを右に (set-scroll-bar-mode right) ;; 圧縮されたファイルを読めるようにする (auto-compression-mode t) ;; y-or-n-p(yes、noではなくy、nだけで答える) (fset yes-or-no-p y-or-n-p) ;; -nwオプションでメニューバーが出ないように (if window-system (menu-bar-mode 1) (menu-bar-mode -1)) ;; 折り返し有りを設定 (setq truncate-lines nil) (setq truncate-partial-width-windows nil) ;; 初期フレームの設定 ;; (Emacsが起動する位置と大きさ お好きなようにどうぞ) (setq default-frame-alist (append (list (width . 80) (height . 63) (top . 50) (left . 700)) default-frame-alist)) ;; スクロールを1行毎に (defun sane-next-line (arg) "Goto next line by ARG steps with scrolling sanely if needed." (interactive "p") (let ((newpt (save-excursion (next-line arg) (point)))) (while (null (pos-visible-in-window-p newpt)) (if ( arg 0) (scroll-down 1) (scroll-up 1))) (goto-char newpt) (setq this-command next-line) ()) ) (defun sane-previous-line (arg) "Goto previous line by ARG steps with scrolling back sanely if needed." (interactive "p") (sane-next-line ( - arg)) (setq this-command previous-line) () ) (defun sane-newline (arg) "Put newline\(s\) by ARG with scrolling sanely if needed." (interactive "p") (let ((newpt (save-excursion (newline arg) (indent-according-to-mode) (point)))) (while (null (pos-visible-in-window-p newpt)) (scroll-up 1)) (goto-char newpt) (setq this-command newline) ())) (global-set-key [up] sane-previous-line) (global-set-key [down] sane-next-line) (global-set-key "\C-m" sane-newline) (define-key global-map "\C-n" sane-next-line) (define-key global-map "\C-p" sane-previous-line) ;; 改行キーでオートインデント (define-key global-map "\C-m" newline-and-indent) ;; 常にカッコの対応をハイライトする (show-paren-mode 1) (setq show-paren-style mixed)
https://w.atwiki.jp/nkym_memo/pages/32.html
;; .emacs ;; ;; Last Updated 2010/12/20 Mon 13 44 34 ;; (if window-system (progn ;; 文字の色を設定 (add-to-list 'default-frame-alist '(foreground-color . "white")) ;; 背景色を設定 (add-to-list 'default-frame-alist '(background-color . "gray7")) ;; カーソルの色を設定 (add-to-list 'default-frame-alist '(cursor-color . "SlateBlue2")) ;; ;; マウスポインタの色を設定 ;; (add-to-list 'default-frame-alist '(mouse-color . "SlateBlue2")) ;; ;; モードラインの文字の色を設定 ;; (set-face-foreground 'modeline "white") ;; ;; モードラインの背景色を設定 ;; (set-face-background 'modeline "MediumPurple2") ;; ;; 選択中のリージョンの色を設定 (set-face-background 'region "Dark Slate Grey") ;; ;; モードライン(アクティブでないバッファ)の文字色を設定 ;; (set-face-foreground 'mode-line-inactive "gray30") ;; ;; モードライン(アクティブでないバッファ)の背景色を設定 ;; (set-face-background 'mode-line-inactive "gray85") )) ;;auto-install.elのインストール手順 ;; $mkdir -p ~/.emacs.d/auto-install ;; cd ~/.emacs.d/auto-install ;; wget http //www.emacswiki.org/emacs/download/auto-install.el ;; emacs --batch -Q -f batch-byte-compile auto-install.el ;;;Emacs Lispインストーラを利用 (add-to-list 'load-path "~/.emacs.d/auto-install") ;;(install-elisp-from-emacswiki "auto-install.el") ;(require 'auto-install) ;;起動時にEmacswikiのページを補完候補に加える ;(auto-install-update-emacswiki-package-name t) ;;install-elisp.el互換モード ;(auto-install-compatibility-setup) ;;ediff関連のバッファを一つのフレームにまとめる (setq ediff-window-setup-function 'ediff-setup-windows-plain) ;;; 基本設定 ;; スタートアップを非表示 (setq inhibit-startup-screen -1) ;; ビープ音を消す (setq ring-bell-function 'ignore) ;; 現在行に色をつける (global-hl-line-mode 1) ;; その行の色 (set-face-background 'hl-line "black") ;; 履歴を次回Emacs起動時にも保存する (savehist-mode 1) ;; 対応する括弧を光らせる (show-paren-mode 1) ;; カーソルの位置が何文字目かを表示する (column-number-mode t) ;; バックアップファイルを作らない (setq backup-inhibited t) ;; Xでのクリップボードを共有 (setq x-select-enable-clipboard t) ;; yes-or-noをy-or-nに省略 (defalias 'yes-or-no-p 'y-or-n-p) ;; 行の先頭でC-kを一回押すだけで行全体を消去する (setq kill-whole-line t) ;; ツールバーを非表示 (tool-bar-mode -1) ;; メニューバーを非表示 (menu-bar-mode -1) ;; 圧縮されたファイルも編集できるようにする (auto-compression-mode t) ;; スクロールを一行ずつにする (setq scroll-step 1) ;;; 現在の関数名をモードラインに表示 (which-function-mode 1) ;;; emacsclient ;; ファイルを現在のemacsで開く (server-start) ;; キーバインドの変更 ;; 指定の行に移る (global-set-key "\M-g" 'goto-line) ;; undo (global-set-key "\C-z" 'undo) ;; ウィンドウの移動をM-tに (global-set-key "\M-t" 'other-window) ;; C-hをBackSpaceに (global-set-key "\C-h" 'delete-backward-char) ;; M-x compile を C-. に (global-set-key [?\C-\.] 'compile) ;;; 初期フレームの設定 (setq initial-frame-alist (append '( (width . 47) ; フレーム幅(文字数) (height . 63)) ; フレーム高(文字数) initial-frame-alist)) ;;; 新規フレームのデフォルト設定 (setq default-frame-alist (append '((width . 47); フレーム幅(文字数) (height . 63)); フレーム高(文字数) default-frame-alist)) ;;; ファイル更新日を自動的に書き換える。 ;; ファイルの頭に "last updated "をつけくわえればよい (require 'time-stamp) ;; 日本語で日付を入れたくないのでlocaleをCにする (defun time-stamp-with-locale-c () (let ((system-time-locale "C")) (time-stamp) nil)) (if (not (memq 'time-stamp-with-locale-c write-file-hooks)) (add-hook 'write-file-hooks 'time-stamp-with-locale-c)) (setq time-stamp-active t) (setq time-stamp-start "Last Updated ") (setq time-stamp-format "%04y/%02m/%02d %3a %02H %02M %02S") (setq time-stamp-end " ") ;;;Last Updated の後に空白2つ以上いれると置換 ;;; タイトルバーにファイル名を表示する (setq frame-title-format (format "emacs@%s %%f" (system-name))) ;;; ファイルの自動挿入 (auto-insert-mode) ;; 自動挿入するファイルのあるディレクトリ ;; 最後の/は必須 (setq auto-insert-directory "~/.emacs.d/insert/") ;; 自動挿入するファイル (define-auto-insert "\\.c" "c-template.c") ;;; viewer.el view-modeの設定 ;; M-x install-elisp-from-emacswiki viewer.el ;; ;; C-x C-rでview-modeでファイルを開く (setq view-read-only t) ;; 書き込み不能な場合はview-modeを抜けないように (require 'viewer) (viewer-stay-in-setup) ;; .log .out .datファイルをview-modeで開く (setq view-mode-by-default-regexp "\\.log") (setq view-mode-by-default-regexp "\\.out") (setq view-mode-by-default-regexp "\\.dat") ;;; view-mode時にモードラインに色をつける ;; 色名を指定 (setq viewer-modeline-color-unwritable "tomato") (setq viewer-modeline-color-view "orange") (viewer-change-modeline-color-setup) ;; view-mode時のキーバインド (define-key view-mode-map "h" 'backward-char) (define-key view-mode-map "j" 'next-line) (define-key view-mode-map "k" 'previous-line) (define-key view-mode-map "l" 'forward-char) (define-key view-mode-map "J" 'View-scroll-line-forward) (define-key view-mode-map "K" 'View-scroll-line-backward) (define-key view-mode-map "b" 'scroll-down) (define-key view-mode-map " " 'scroll-up) ;; bm.el (define-key view-mode-map "m" 'bm-toggle) (define-key view-mode-map "[" 'bm-previous) (define-key view-mode-map "]" 'bm-next) ;; view-modeを有効・無効にする ;; 0.04秒以内に jk を同時押しでview-modeに移行 (require 'key-chord) (setq key-chord-two-keys-delay 0.04) (key-chord-mode 1) (key-chord-define-global "jk" 'view-mode) ;;; redo+.el (require 'redo+) ;; M-zに設定 (global-set-key "\M-z" 'redo) (setq undo-no-redo t); 過去のundoがredoされないようにする ;; 大量のundoに耐えられるようにする (setq undo-limit 600000) (setq undo-strong-limit 900000) ;;;fullscreen.el (require 'fullscreen) ;;; recentf-ext.el ;; install-elisp-from-emacswiki recentf-ext.el ;; 保存しておく数 (setq recentf-max-saved-items 3000) ;; 最近使ったファイルに加えないファイルを正規表現で指定する (setq recentf-exclude '("/TAGS$" "/var/tmp/")) (require 'recentf-ext) ;; f8をショートカットキーに (global-set-key [f8] 'recentf-open-files) ;;; auto-complete.el ;; install-elisp-from-emacswiki auto-complete.el ;(require 'auto-complete) ;(global-auto-complete-mode 1) ;;;col-highlight.el ;; auto-install-batch col-highlight.el ;(require 'col-highlight) ;(column-highlight-mode 1) ;;何もしないでいるとハイライトを始めるようにする場合 ;(toggle-highlight-column-when-idle 1) ;(col-highlight-set-interval 3) ;;; hippie-expand ;;; 略語展開の順を設定 (setq hippie-expand-try-functions-list '(try-expand-dabbrev try-expand-dabbrev-all-buffers try-expand-dabbrev-from-kill try-complete-file-name-partially try-complete-file-name try-expand-all-abbrevs try-expand-list try-expand-line try-complete-lisp-symbol-partially try-complete-lisp-symbol)) ;; キーバインドの変更 C-; (global-set-key [?\C-;] 'hippie-expand) ;;; ipa.el (require 'ipa) ;;; 背景色 (set-face-background 'highlight "lavender") ;;; sequential-command.el ;;; M-x auto-install-batch sequential-command (require 'sequential-command-config) (sequential-command-setup-keys) ;;; smartchr.el ;; M-x install-elisp ;; https //github.com/imakado/emacs-smartchr/raw/master/smartchr.el (require 'smartchr) ;; once "", twice " (global-set-key (kbd "\"") (smartchr '("\"`!!'\"" "\""))) ;; once '', twice ' (global-set-key (kbd "\'") (smartchr '("\'`!!'\'" "\'"))) ;;; auto-save-buffers.el ;; M-x install-elisp ;; http //homepage3.nifty.com/oatu/emacs/archives/auto-save-buffers.el (require 'auto-save-buffers) ;; アイドル2秒で保存 (run-with-idle-timer 0.2 t 'auto-save-buffers) (run-with-idle-timer 0.2 t 'auto-save-buffers "" ".ipa$") ;;; open-junk-file.el ;; M-x install-elisp-from-emacswiki open-junk-file.el ;; Usage M-x open-junk-file (require 'open-junk-file) (setq open-junk-file-format "~/junk/%Y-%m-%d-%H%M%S.") ;;; bm.el ;; M-x install-elisp ;; http //cvs.savannah.gnu.org/viewvc/*checkout*/bm/bm/bm.el (setq-default bm-buffer-persistence nil) (setq bm-restore-repository-on-load t) (require 'bm) (add-hook 'find-file-hooks 'bm-buffer-restore) (add-hook 'kill-buffer-hook 'bm-buffer-save) (add-hook 'after-save-hook 'bm-buffer-save) (add-hook 'after-revert-hook 'bm-buffer-restore) (add-hook 'vc-before-checkin-hook 'bm-buffer-save) (global-set-key (kbd "M-\\") 'bm-toggle) (global-set-key (kbd "M-[") 'bm-previous) (global-set-key (kbd "M-]") 'bm-next) ;;; Latex ;; 日本語コードをeuc-japanに (set-language-environment "Japanese") (set-default-coding-systems 'euc-japan) (set-terminal-coding-system 'euc-japan) ;;; Yatex (setq YaTeX-inhibit-prefix-letter nil) ;;; twittering-mode (add-to-list 'load-path "~/.emacs.d/twittering-mode-1.0.0/") (require 'twittering-mode) ;; Show icons (setq twittering-icon-mode t) ;; Update your timeline each 300 seconds (5 minutes) (setq twittering-timer-interval 30) (add-hook 'twittering-mode-hook (lambda () (mapc (lambda (pair) (let ((key (car pair)) (func (cdr pair))) (define-key twittering-mode-map (read-kbd-macro key) func))) '(("F" . twittering-friends-timeline) ("R" . twittering-replies-timeline) ("U" . twittering-user-timeline) ("W" . twittering-update-status-interactive)))))
https://w.atwiki.jp/norio515/pages/18.html
Objective-C mode You can activate objective-c mode to write following code in .emacs.el (add-to-list auto-mode-alist ("\\.mm?$" . objc-mode)) (add-to-list auto-mode-alist ("\\.h$" . objc-mode)) You can activate auto-complement to use auto-complete, company-mode, ac-company. These el files are downloaded and extracted to ~/.emacs/lisp cd ~/.emacs.d/lisp curl -O http //cx4a.org/pub/auto-complete/auto-complete-1.3.tar.bz2 curl -O http //nschum.de/src/emacs/company-mode/company-0.5.tar.bz2 curl -O http //github.com/buzztaiki/auto-complete/raw/master/ac-company.el tar xvfj auto-complete-1.3.tar.bz2 tar xvfj company-0.5.tar.bz2 Implements following code in .emacs.el to activate el files. ;(add-to-list load-path "~/.emacs.d/lisp") (let ((default-directory (expand-file-name "~/.emacs.d/lisp"))) (add-to-list load-path default-directory) (if (fboundp normal-top-level-add-subdirs-to-load-path) (normal-top-level-add-subdirs-to-load-path))) (require auto-complete-config) (require ac-company) (global-auto-complete-mode t) (ac-company-define-source ac-source-company-xcode company-xcode) (setq ac-modes (append ac-modes (objc-mode))) (add-hook objc-mode-hook (lambda () (define-key objc-mode-map (kbd "\t") ac-complete) (push ac-source-company-xcode ac-sources) )) (define-key ac-completing-map (kbd "C-n") ac-next) (define-key ac-completing-map (kbd "C-p") ac-previous) (define-key ac-completing-map (kbd "M-/") ac-stop) (setq ac-auto-start nil) (ac-set-trigger-key "TAB") Tab indent is set by 4 space. (add-hook c-mode-common-hook (lambda() (c-set-style "cc-mode"))) (setq-default indent-tabs-mode nil) (setq-default tab-width 4) Auto inserting Arcs. (add-hook c-mode-common-hook (lambda() (make-variable-buffer-local skeleton-pair) (make-variable-buffer-local skeleton-pair-on-word) (setq skeleton-pair-on-word t) (setq skeleton-pair t) (make-variable-buffer-local skeleton-pair-alist) (local-set-key (kbd "(") skeleton-pair-insert-maybe) (local-set-key (kbd "[") skeleton-pair-insert-maybe) (local-set-key (kbd "{") skeleton-pair-insert-maybe) (local-set-key (kbd "`") skeleton-pair-insert-maybe) (local-set-key (kbd "\"") skeleton-pair-insert-maybe) ))
https://w.atwiki.jp/astrophysics/pages/19.html
Emacsのメモページ C- はctrl-を意味する。 Emacs Command集 上書き保存 C-x C-s 名前をつけて保存 C-x C-w 検索する C-s でインクリメンタルサーチができる。 置換する Alt-x としたあと replace-string と代入して Enter をおす。 削除 C-k コピペ C-k C-y コピペ第二弾 ドラッグでコピー。ペーストは Shit-Ins 1画面進む Ctrl+v 1画面戻る Alt+v 行頭に移る Ctrl+a 行末に移る Ctrl+e *
https://w.atwiki.jp/141oboegaki/pages/16.html
emacs 「C」はコントロールキー 起動 コマンドライン上で emacs (-nw) (filename) 閉じる C-x C-c 一行カット・ペースト C-k C-y 上書き保存 C-x C-s 別名で保存 C-x C-w 検索・置換がイマイチわかんね 今度やってみよ @anapaw sh sh (コマンドライン上のコマンド) ex) sh lpr hoge.ps hoge.ps を印刷 Xの範囲指定 blo x1 x2 Yの範囲指定 mami y1 y2 マクロ引数 マクロ中に[1],[2]等
https://w.atwiki.jp/hideaki0121/pages/100.html
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Emacs / XEmacs 用ユーザ設定ファイル ;; MATSUBAYASHI Shaolin Kohji (shaolin@vinelinux.org) ;; Irokawa 烈風戦士 Hiroaki (irorin@terra.dti.ne.jp) ;; Time-stamp 07/02/02 15 25 42 miyanishi ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; ソフトウェアシステム分野用にアレンジ ;; Hirohisa AMAN aman@cs.ehime-u.ac.jp ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Emacs か XEmacs かの判定 ;; ここで Emacs 用、XEmacs 用の設定ファイルを切替えます ;; ;; ~/.emacs.vine40.el - Emacs 用設定ファイル (Vine Linux 4.0用) ;; ~/.emacs.vine31.el - Emacs 用設定ファイル (Vine Linux 3.1用) ;; ~/.xemacs.el - XEmacs-21.1 用設定ファイル ;; ~/.xemacs/init.el - XEmacs 用設定ファイル (if (string-match "^XEmacs" (emacs-version)) (if (string-match "21.1" emacs-version) (load (expand-file-name "~/.xemacs.el") nil t nil) (load (expand-file-name "~/.xemacs/init.el") nil t nil)) (if (string-match "21.4" (emacs-version)) (load (expand-file-name "~/.emacs.vine40.el") nil t nil) (load (expand-file-name "~/.emacs.vine31.el") nil t nil)) )
https://w.atwiki.jp/tanks/pages/14.html
EmacsMEMO .emacs